package com.example.testandroidswipelayout1

import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.util.Log
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.LinearLayout
import com.daimajia.swipe.SwipeLayout

class MainActivity : AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)

//        findViewById<LinearLayout>(R.id.bird_bottom).setOnClickListener {
//            Log.e("young_test9090909","dian ji")
//        }

        val decorView = window.decorView as ViewGroup

        val view = LayoutInflater.from(this).inflate(R.layout.activity_main1, decorView, false)

        val slLayout = view.findViewById<SwipeLayout>(R.id.sl_layout)

        view.findViewById<View>(R.id.bottomView).setOnClickListener {
            Log.e("young_test90909","hello young_test90909")
        }

        decorView.addView(view)
    }
}